package com.elite.annotation.config;

import org.springframework.context.annotation.Configuration;
import org.springframework.transaction.annotation.EnableTransactionManagement;

/**
  * @EnableTransactionManagement 默认为容器导入两个组件：AutoProxyRegistrar 以及 ProxyTransactionManagementConfiguration
  * 1.AutoProxyRegistrar: 为容器导入一个InfrastructureAdvisorAutoProxyCreator(本质和AnnotationAwareAspectJAutoProxyCreator一样) bean代理的后置处理器
  * 2.ProxyTransactionManagementConfiguration
  * 	为容器注入一个事物增强器这个增加器需要下面的两个类：
  * 		AnnotationTransactionAttributeSource解析事物@Transaction注解信息
  * 		TransactionInterceptor 事物的拦截器
 */
@Configuration
@EnableTransactionManagement
public class TransactionConfig {
}
